-- stack: in. II Cards -- format: 8 (HyperCard 1) -- flags: 0x1000 (none) -- protect password hash: 0 -- maximum user level: 5 (scripting) -- window: Rect(x1=0, y1=0, x2=0, y2=0) -- screen: Rect(x1=0, y1=0, x2=0, y2=0) -- card dimensions: w=0 h=0 -- scroll: x=0 y=0 -- background count: 1 -- first background id: 2763 -- card count: 1 -- first card id: 75250 -- list block id: 2056 -- print block id: 0 -- font table block id: 0 -- style table block id: 0 -- free block count: 0 -- free size: 0 bytes -- total size: 61216 bytes -- stack block size: 9216 bytes -- created by hypercard version: 0x00000000 -- compacted by hypercard version: 0x01208000 -- modified by hypercard version: 0x01208000 -- opened by hypercard version: 0x01208000 -- patterns[0]: 0x0000000000000000 -- patterns[1]: 0x8000000008000000 -- patterns[2]: 0x8800220088002200 -- patterns[3]: 0x8888222288882222 -- patterns[4]: 0x88AA22AA88AA22AA -- patterns[5]: 0xCCAA33AACCAA33AA -- patterns[6]: 0xEEAABBAAEEAABBAA -- patterns[7]: 0xEEBBBBEEEEBBBBEE -- patterns[8]: 0xFFBBFFEEFFBBFFEE -- patterns[9]: 0xFFBBFFFFFFBBFFFF -- patterns[10]: 0x8010022001084004 -- patterns[11]: 0xFFFFFFFFFFFFFFFF -- patterns[12]: 0x8822882288228822 -- patterns[13]: 0x1122448811224488 -- patterns[14]: 0xC4800C6843023026 -- patterns[15]: 0xB130031BD8C00C8D -- patterns[16]: 0xAA00AA00AA00AA00 -- patterns[17]: 0x8822552288225522 -- patterns[18]: 0x8855225588552255 -- patterns[19]: 0x77DD77DD77DD77DD -- patterns[20]: 0x8000000000000000 -- patterns[21]: 0xAA55AA55AA55AA55 -- patterns[22]: 0x038448300C020101 -- patterns[23]: 0x8244394482010101 -- patterns[24]: 0x8814224188412214 -- patterns[25]: 0x8080413E080814E3 -- patterns[26]: 0x22048C7422179810 -- patterns[27]: 0xBE808808EB088880 -- patterns[28]: 0x25C8328964244C92 -- patterns[29]: 0xA29C41BE2AC914EB -- patterns[30]: 0x40A00000040A0000 -- patterns[31]: 0x8040200002040800 -- patterns[32]: 0xAA00800088008000 -- patterns[33]: 0xFF80808080808080 -- patterns[34]: 0x081C22C180010204 -- patterns[35]: 0xFF808080FF080808 -- patterns[36]: 0xF87422478F172271 -- patterns[37]: 0xBF00BFBFB0B0B0B0 -- patterns[38]: 0xFF7FBE5DA2418000 -- patterns[39]: 0xFAF5FAF5A050A050 -- checksum: 0x0 ----- HyperTalk script ----- on openStack hide MenuBar global stype, coping, activef, writetype, sandwm put empty into sandwm hide message if coping <> "Yes" then set the name of bg btn 31 to "Stack: " && the short name of this stack put the short name of this stack into activef put 0 into stype put empty into writetype end if pass openStack end openStack -- BIB. MAN. II CARDS v. 1.2 -- LAST UPDATE: 9/30/90 function DelEntry global userlevel put "Checking for Details..." lock screen put the userlevel into ulev set the userlevel to 3 if the script of this cd = "d" then -- DELETE DETAILS CARD put "Deleting Details for Reference Number " & fld Rnum & "..." click at 475,247 --CLICK SHOW BUTTON get the script of this bg if it = "xyzzy" then if (the number of cds of bg DetBkgnd) < 2 then repeat with i = 3 to 6 put empty into fld i end repeat else doMenu Delete Card end if else beep answer "ERROR: Could not locate Details stack" end if pop cd --RETURN TO DATA STACK CARD (PUSHED IN SHOW BUTTON SCRIPT) end if put "Deleting Reference Number " & fld Rnum & "..." -- DELETE BIB. STACK CARD if (the number of cds of bg "Data Card bkgnd") < 2 then repeat with i = 1 to 7 put empty into fld i end repeat set the script of fld Rnum to "1" else doMenu Delete Card end if set the userlevel to ulev end DelEntry function FormAuthor Fir,fmt if fmt = 1 then put last word of Fir into Las delete last word of Fir repeat until last char of Las <> space and last char of Las <> "." delete last char of Las end repeat else put first word of Fir into Las delete first word of Fir end if if last char of Las <> "," then put "," after Las put 1 into i repeat for the number of words in Fir repeat until last char of word i of Fir <> "," delete last char of word i of Fir end repeat if the number of chars in word i of Fir = 1 then put "." after word i of Fir add 1 to i end repeat repeat until last char of Fir <> space delete last char of Fir end repeat return Las && Fir end FormAuthor function FormInAuth inAuth global inauthform put empty into lastauth put offset (" and ",inAuth) into ans --FIND LAST AUTHOR IF HAS "AND" if ans = 0 then put offset (" & ",inAuth) into ans --OR "&" if ans <> 0 then put return into char ans of inAuth delete word 1 of line 2 of inAuth put FormAuthor(line 2 of inAuth,line 2 of inauthform) into lastauth delete line 2 of inAuth delete last char of inAuth end if if the number of words in inAuth < 4 then put FormAuthor(inAuth,line 1 of inauthform) into outtxt if lastauth is not empty then put return & lastauth after outtxt return outtxt end if put the number of words in inAuth into wdcnt if line 3 of inauthform = 1 then --IF NO SEPARATING COMMAS CHECK RATIO put empty into lnloc --OF NAMES TO INITALS repeat with i = 1 to wdcnt if the number of chars in word i of inAuth > 2 then put i & return after lnloc end if end repeat put the number of lines in lnloc into lnnum if lnnum < 2 or wdcnt < 4 then --IF ALL WORDS INITIALS OR --ONLY < 4 WORDS, ASSUME ONLY ONE NAME AND RETURN OUTTXT put FormAuthor(inAuth,line 1 of inauthform) into outtxt if lastauth is not empty then put return & lastauth after outtxt return outtxt end if --ELSE if lnnum/wdcnt < 0.5 then --IF RATIO < 1/2, ASSUME LONG NAMES if line 1 of inauthform = 1 then --ARE LAST NAMES if line 2 of inauthform = 1 then --IF ALL F L, THEN ARE LOCS put lnloc into nlocs else --ELSE DERIVE LOCS OF END OF NAMES if line 1 of lnloc <> line 2 of lnloc - 1 then put line 1 of lnloc - 1 & return into nlocs else put line 1 of lnloc & return into nlocs end if if lnnum < 3 then put wdcnt after nlocs else repeat with i = 3 to lnnum put (line i of lnloc) - 1 & return after nlocs end repeat put wdcnt after nlocs end if end if else --IF FIRST AUTHOR IS L F THEN if line 2 of inauthform = 1 then --IF COAUTHORS F L THEN if line 1 of lnloc = 1 then delete line 1 of lnloc if line 1 of lnloc > 3 then put (line 1 of lnloc) - 3 & return before lnloc put lnloc into nlocs else put empty into nlocs if line 1 of lnloc <> 1 then repeat with i = 1 to lnnum put (line i of lnloc) - 1 & return after nlocs end repeat else delete line 1 of lnloc repeat with i = 1 to lnnum-1 put (line i of lnloc) - 1 & return after nlocs end repeat end if put wdcnt after nlocs end if end if else --ELSE... THAT IS, IF CAN'T ASSUME LONG NAMES ARE LAST NAMES put empty into nlocs put 3 into i --DO BY THREES AND HOPE FOR THE BEST repeat until i >= wdcnt put i & return after nlocs add 3 to i end repeat put wdcnt after nlocs end if else --IF THERE ARE SEPARATING COMMAS put empty into nlocs --IF ALL L, F THEN NAMES END AT EACH 2ND COMMA if line 1 of inauthform = 3 and line 2 of inauthform = 3 then put 0 into cnt repeat with i = 1 to wdcnt if last char of word i of inAuth = "," then add 1 to cnt if cnt = 2 then put i & return after nlocs put 0 into cnt end if end repeat if last line of nlocs <> wdcnt then put wdcnt after nlocs end if else --ELSE (NAMES NOT ALL L, F) if line 1 of inauthform = 3 then put 0 into i --IF FIRST AUTHOR IS L, F THEN FIND FIRST put 0 into cnt --AUTHOR (ENDS AT 2ND COMMA); REST WILL BE DONE repeat until i = 2 --WITH OTHER CHOICE (NO COMMAS WITHIN NAMES) add 1 to cnt if last char of word cnt of inAuth = "," then add 1 to i if cnt = wdcnt then exit repeat end repeat put cnt & return after nlocs add 1 to cnt else put 1 into cnt end if repeat with i = cnt to wdcnt --DO FOR ANY THAT ONLY HAVE COMMAS if last char of word i of inAuth = "," then --SEPARATING AUTHOR put i & return after nlocs --NAMES (NO COMMAS WITHIN NAMES) end if end repeat if last line of nlocs <> wdcnt then put wdcnt after nlocs end if end if put empty into toauthform --WRITE NAMES TO TEXT FOR OUTPUT repeat with i = 1 to line 1 of nlocs --DO FIRST AUTHOR put word i of inAuth & space after toauthform end repeat put FormAuthor(toauthform,line 1 of inauthform) & return into outtxt put empty into toauthform put the number of lines in nlocs into nnums repeat with i = 2 to nnums --DO COAUTHORS repeat with j = ((line (i - 1) of nlocs) + 1) to line i of nlocs put word j of inAuth & space after toauthform end repeat put FormAuthor(toauthform,line 2 of inauthform) & return after outtxt put empty into toauthform end repeat if lastauth is not empty then put lastauth after outtxt --ADD LAST return outtxt --AUTHOR (IF HAD "AND") AND RETURN end FormInAuth on closeCard global sandwm if sandwm is empty then if the short name of this bg = "Data Card bkgnd" then repeat with i = 1 to 4 set scroll of fld round(1 + i*1.4) to 0 end repeat end if end if end closeCard on idle global seltext, sandwm if (sandwm = 996) and (the short name of this bg = "Data card bkgnd") then put 995 into sandwm click at the loc of bg btn "Find Next Match" else if the selection is empty then put empty into seltext else put the selectedtext & return & the selectedfield into seltext end if end if end idle